﻿namespace GX
{
    public class NetHandlerBase : INetHandler
    {
        protected System.Object _data;
        public NetHandlerBase(System.Object data = null)
        {
            this._data = data;
        }
        public ushort code
        {
            get
            {
                ushort v = 0;
                v += (ushort)(frame << 8);
                v += (ushort)way;
                return v;
            }
        }
        virtual public byte frame { get { return 0; } }
        virtual public byte way { get { return 0; } }
        virtual public void HandlePackage(IPackageIn pkg) { }
    }
}